home *** CD-ROM | disk | FTP | other *** search
/ A.C.E. 1 / ACE CD 1.iso / files / utils / acroarex.dms / in.adf / Demo / ARCO_DEMO.acrx < prev    next >
Encoding:
Text File  |  1994-06-10  |  4.5 KB  |  145 lines

  1. /**********************************************************************/
  2. /*                  This is a demonstration of ArCo,                  */
  3. /*                 In fact Its more of a guided tour                  */
  4. /*                            08 Jun 1994                             */
  5. /*                         © Michael A Sewell                         */
  6. /**********************************************************************/
  7.  
  8. Options RESULTS
  9.  
  10. LF = '0A'X    /* line feed */
  11.  
  12. IF ~SHOW('L','rexxsupport.library') then
  13.    CALL ADDLIB('rexxsupport.library',0,-30)
  14.  
  15. IF ~SHOW('P', 'ARCO') THEN DO
  16.     Address COMMAND
  17.         'run >NIL: <NIL: ARCO:ARCO'    /* run ARCO */
  18.         'WaitForPort' 'ARCO'        /* WaitForPort needs to be in the path */
  19.         IF RC ~= 0 THEN DO        /* couldn't find ARCO */
  20.         SAY 'Cant start ArCo, No Show = No Go!'
  21.         exit
  22.     end
  23. end
  24.  
  25. Address 'ARCO'
  26. VERBOSE        /* Make sure they can get the messages */
  27. TELL "Welcome to the ArCo Demo"LF"Actually it's more of a tour"
  28. CALL timedelay( 3 )
  29. TELL "Lets see what we have here?"
  30. CALL timedelay( 2 )
  31. TELL "Lets just reset everything"LF"Except for the verbose option"
  32. CALL timedelay( 2 )
  33. VERSION "FALSE"        /* Switch off these three */
  34. RUN "FALSE"
  35. WRITEICON "FALSE"
  36. RESETLIBLIST        /* Remove all link libraries from the list */
  37. CANCELTRACE        /* Clear all trace options */
  38. CANCELINTERRUPTS    /* Clear all interrupt options */
  39. CANCELARGS        /* Clear all Arg options */
  40. TELL "Thats cleared everything!"
  41. CALL TIMEDELAY( 2 )
  42. TELL "We are now going to close the"LF"Main Panel & iconify,I'll reopen"LF"this window in about 5 secs"
  43. CALL TIMEDELAY( 3 )
  44. ICONIFY
  45. CALL TIMEDELAY( 5 )
  46. OPENGUI
  47. TELL "Welcome Back!"
  48. CALL TIMEDELAY( 1 )
  49. TELL "We will now take a look at some"LF"of the requestors"
  50. CALL TIMEDELAY( 2 )
  51. TELL "While these are open, feel free"LF"to make any selections"
  52. CALL TIMEDELAY( 2 )
  53. TELL "They will be closed after about"LF"15 seconds!"
  54. CALL TIMEDELAY( 2 )
  55. TELL "Lets take a look at the TRACE"LF"options available"
  56. CALL TIMEDELAY( 2 )
  57. LAUNCHMACRO "ARCO:DEMO/tracetest.acrx"     /* This must be launched as an */
  58.                     /* exterior macro so that the */
  59.                     /* requestor closes after a period */
  60.                     /* of time */
  61. GETTRACE
  62. TELL "Now lets take a look at the"LF"Interrupt options available"
  63. CALL TIMEDELAY( 2 )
  64. LAUNCHMACRO "ARCO:DEMO/interrupttest.acrx"    /* See above */
  65. GETINTERRUPTS
  66. TELL "Now lets take a look at the"LF"Argument options available"LF"We will have to set RUN"
  67. CALL TIMEDELAY( 2 )
  68. RUN
  69. LAUNCHMACRO "ARCO:DEMO/argstest.acrx"    /* see above */
  70. GETARGS
  71. TELL "I think you've seen them all"LF"Except for the EGO trip!"
  72. CALL TIMEDELAY( 2 )
  73. RUN FALSE
  74. LAUNCHMACRO "ARCO:DEMO/EGOtest.acrx"    /* yeah ! */
  75. SHOWABOUT    /* I hate myself for this !!!!! */
  76. TELL "Look at the output options"LF"I'll go through them slowly"
  77. CALL TIMEDELAY( 4 )
  78. SETOUTPUT "LIBRARYOBJECT"
  79. CALL TIMEDELAY( 3 )
  80. SETOUTPUT "LINKOBJECT"
  81. CALL TIMEDELAY( 3 )
  82. SETOUTPUT "SCRIPT"
  83. CALL TIMEDELAY( 3 )
  84. SETOUTPUT    /* resets to default EXECUTABLE */
  85. CALL TIMEDELAY( 3 )
  86. TELL "Now lets compile something,"LF"We will compile our first souce"LF"file into an executable"
  87. CALL TIMEDELAY( 5 )
  88. TELL "Lets set the source file gadget"
  89. CALL TIMEDELAY( 2 )
  90. SETSRCFILE "YOOHOO!"
  91. CALL TIMEDELAY( 2 )
  92. TELL "Only kidding, Sorry about that"
  93. CALL TIMEDELAY( 2 )
  94. SETSRCFILE "ARCO:EXAMPLES/MARQUIS.rexx"
  95. CALL TIMEDELAY( 2 )
  96. TELL "There you go"LF"We'll save the object file to"LF"the RAM: disk, Save disk space"
  97. CALL TIMEDELAY( 4 )
  98. SETOBJFILE "RAM:MARQUIS.o"
  99. CALL TIMEDELAY( 2 )
  100. TELL "Lets save the executable to"LF"RAM: for the same reasons"
  101. CALL TIMEDELAY( 3 )
  102. SETEXECFILE "RAM:MARQUIS"
  103. CALL TIMEDELAY( 2 )
  104. TELL "We want to add a few things such"LF"as icons, and a version string"
  105. CALL TIMEDELAY( 3 )
  106. VERSION
  107. WRITEICON
  108. CALL TIMEDELAY( 2 )
  109. TELL "I'm also going to run it after"LF"compilation,In a CLI environment"
  110. CALL TIMEDELAY( 3 )
  111. RUN
  112. TELL "Clearing any options you may"LF"have set for Interrupts,"LF"trace or Arguments"
  113. RESETTRACE
  114. RESETINTERRUPTS
  115. RESETARGS
  116. SETCLIARGS "An_ArCo_User!"    /* This is picked up by marquis */
  117. TELL "I think it's time to compile!"
  118. CALL TIMEDELAY( 2 )
  119. COMPILE
  120. TELL LF
  121. TELL LF
  122. TELL LF
  123. TELL LF
  124. TELL "ALL DONE!"  /* All those linefeeds clear the window */
  125. CALL TIMEDELAY( 10 )    /* Have to make sure that marquis is done before us */
  126. TELL "Thank you for your patience"LF"This Demonstration is now"LF"over, Goodbye"
  127. CALL TIMEDELAY( 3 ) /* Or else its the big boom! */
  128. REXXONLY
  129. CALL TIMEDELAY( 15 )
  130. REQUEST "I lied!, This shows ArCo in"LF"REXXONLY form, ArCo will"LF"exit on closing this requestor."
  131. CALL TIMEDELAY( 5 )    /* Just to be sure */
  132. QUIT
  133.  
  134.  
  135.  
  136. TIMEDELAY:
  137. PARSE ARG number
  138.  
  139. CALL time 'R'
  140. DO WHILE time('E') < number
  141.     nop
  142. end
  143. RETURN
  144.  
  145.